Implementation of agitation care algorithm